package com.vgulu.server.login.service;

import com.vgulu.server.login.bean.LoginBean;
import com.vgulu.server.login.repository.entity.Uid;
import org.springframework.web.bind.annotation.RequestParam;

/**
 * uid是用户相对于某个项目的唯一身份识别号
 * Created by wangchunsee on 16/10/4.
 */
public interface UserService {
    /**
     * 验证Token
     * @param token
     * @return 成功:返回uid,失败:返回空
     */
    Uid checkToken(String token);

    LoginBean qqLogin(String appId, String openId, String accessToken,String channel);

    LoginBean emailRegister(String appId,String email,String pwd,String channel);

    LoginBean emailLogin(String appId,String email,String pwd,String channel);

    void emailResetPwd(String appId,String email);

    LoginBean modifyPwd(String appId,String token,String oldPwd,String newPwd,String channel);

    LoginBean mobileRegister(String appId, String mobile, String pwd, String smsCode, String channel);

    LoginBean mobileLogin(String appId, String mobile, String pwd, String channel);

    LoginBean wxlogin(String appId, String code);
}
